import Vue from 'vue'
import VueRouter from 'vue-router'

Vue.use(VueRouter)

const routes = [
  {
    path: '/',
    redirect: '/login',
    hidden: true
  },
  {
    path: '/login',
    name: 'login',
    component: () => import('@/views/LoginView'),
    hidden: true
  },
  // {
  //   path: '*',
  //   name: 'NotFound',
  //   component: () => import('@/views/NotFound'),
  //   hidden: true
  // },
  {
    path: '/home',
    name: '衣物字典',
    redirect: 'home/clothingDict',
    fontawesome: 'fa fa-info',
    component: () => import('@/views/HomeView'),
    children: [
      {
        path: '/home/clothingDict',
        name: '字典索引',
        fontawesome: 'fa fa-list',
        component: () => import('@/views/clothingDict')
      },
      {
        path: '/home/clothingDetail',
        name: '字典详细',
        fontawesome: 'fa fa-table',
        component: () => import('@/views/clothingDetail')
      },
      {
        path: '/home/clothingPic',
        name: '衣物照片',
        fontawesome: 'fa fa-table',
        component: () => import('@/views/clothingPic')
      },
      {
        path: '/home/clothingPics',
        name: '衣物照片',
        fontawesome: 'fa fa-table',
        component: () => import('@/views/clothingPics')
      },
      {
        path: '/home/clothingPices',
        name: '衣物照片',
        fontawesome: 'fa fa-table',
        component: () => import('@/views/clothingPices')
      }, {
        path: '/home/clothingupload',
        name: '衣物照片',
        fontawesome: 'fa fa-table',
        component: () => import('@/views/clothingupload')
      },
    ]
  },
]

const router = new VueRouter({
  routes
})

export default router
